package com.crtf.hello.kotlin.lombok.java.dto.impl;

import com.crtf.hello.kotlin.lombok.java.dto.FishDTO;
import jakarta.validation.constraints.Max;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotNull;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;


@Data
@Builder
@NoArgsConstructor
public class GoldfishDTO implements FishDTO {

    public GoldfishDTO(Integer age) {
        this.age = age;
    }

    private final String name = "金鱼";

    @NotNull
    @Min(0)
    @Max(100)
    private Integer age;
}
